home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Turnbull China Bikeride
/
Turnbull China Bikeride - Disc 2.iso
/
STUTTGART
/
COMM
/
INTERNET
/
MAIL
/
TRANSPORTS
/
taylor
/
DoPost
< prev
next >
Wrap
Text File
|
1994-09-19
|
2KB
|
53 lines
| > DoPost
|
| Version for compressed news batches
| Usage: DoPost <NewsServerAddress> <Filename>
|
| DoPost will queue the specified file for posting to News via the
| specified NewsServer. It performs no error checking on the file, and
| assumes that the file contains a valid header.
|
| This version of DoPost produces single, compressed news batches
| for sending straight to the other end.
|
| Author: Gunnar Zötl
| Date: 17-Sep-1994
| Last Modified: 19-Sep-1994
|
| We need some more memory than the non-compressing version
|
wimpslot -min 700K
|
| We create a temporary file in Wimp$ScrapDir, to which we compress the
| article
|
set f <Wimp$ScrapDir>.DPtemp
|
| if you want to use gzip instead of compress, change cunbatch to zunbatch
| and compress to gzip.
|
<obey$dir>.printto <f> #! cunbatch
compress < %1 >> <f> 2> null:
|
| this gets around a problem with the C library, which sometimes seems
| confused then receiving a <system$variable> together with I/O redirection.
Set alias$DoPostIt Uux -r - %0!rnews < <f> 2> null:
|
| we assume that posting the article will succeed.
|
Set NewsBase$ReturnInfo Article posted
DoPostIt
Set NewsBase$ReturnCode <Sys$ReturnCode>
|
| If posting did not succeed, we alter the Info for NewsBase here.
|
If "<NewsBase$ReturnCode>" <> "0" Then Set NewsBase$ReturnInfo Posting failed
|
| now remove the file sendnews passed us, the temp. file, and unset the
| helper environment variables
|
Remove %1
Remove <f>
unset f
unset alias$DoPostIt